package com.wonders.frame.controller;

import com.gcr.server.response.Response;
import com.gcr.server.response.ResponseCodeEnum;
import com.wonders.frame.common.Enum.InitCommonSourceEnum;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/commonSource")
public class CommonSourceController {

    @RequestMapping("getCommonSource")
    public Response getCommonSource(String key){
        Response response = new Response();
        response.setContent(InitCommonSourceEnum.getCommonSource(key));
        response.setCode(ResponseCodeEnum.SUCCESS.getCode());
        response.setMsg(ResponseCodeEnum.SUCCESS.getMsg());
        return response;
    }
}
